package com.soft.line.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonInclude;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotNull;
import java.util.Date;

@Data
@NoArgsConstructor
@AllArgsConstructor
public class CertificateInfo {

    private Integer id;

    @ApiModelProperty(value = "证书ID")
    @Length(max = 200,message="证书ID不能大于200位")
    private String certId;

    @ApiModelProperty(value = "证书类型")
    @NotNull(message = "证书类型不能为空")
    private String certType;

    @ApiModelProperty(value = "证书名称")
    @NotNull(message = "证书名称不能为空")
    @Length(max = 100,message="证书名称不能大于100字")
    private String certName;

    @ApiModelProperty(value = "颁发单位")
    @NotNull(message = "颁发单位不能为空")
    @Length(max = 200,message="颁发单位不能大于200字")
    private String certUnit;

    @ApiModelProperty(value = "发证日期")
    @JsonFormat(pattern = "yyyyMMdd",timezone = "Asia/Shanghai")
    private Date beginDate;

    @ApiModelProperty(value = "到期日期")
    @JsonFormat(pattern = "yyyyMMdd",timezone = "Asia/Shanghai")
    private Date endDate;

    @Length(max = 200,message="备注不能大于200字")
    private String note;

    private String modifyPerson;

    @JsonFormat(pattern = "yyyyMMdd",timezone = "Asia/Shanghai")
    private Date modifyTime;

    private String delFlg;

    @ApiModelProperty(value = "颁发日期")
    @JsonFormat(pattern = "yyyyMMdd",timezone = "Asia/Shanghai")
    private Date issueDate;

}